home *** CD-ROM | disk | FTP | other *** search
/ PC Pro 2005 July / DPPCPRO0705.ISO / Extras / NetSupport Manager / setup.exe / VIEW.SCP < prev    next >
Encoding:
Text File  |  2004-10-06  |  2.1 KB  |  62 lines

  1. // Author :        Andy Earp(NetSupport Ltd) 
  2. // File name :         Clientlist.scp
  3. // Date created :        17/08/00
  4. // Description : 
  5. //        Short script that will prompt the user for input and then connect to the Client machine and if the connection is established
  6. //        it will then open a view window of the Client machine. 
  7.  
  8. //Main description at the start of the script
  9.  
  10. Print "***********************************************************"
  11. Print " "
  12. Print " This is a sample script that will prompt the user to"
  13. Print " enter the name of the Client they wish to connect."
  14. Print " The script will then go on to open a view window "
  15. Print " of the Client machine." 
  16. Print " "
  17. Print "To end the script close down the view window."
  18. Wait (7)
  19.  
  20. // Sets the transport to connect over, this example is using the TCP/IP protocol.
  21. SetTransport(T_TCPIP)
  22.  
  23. // Declares Variable used
  24. Dim Client
  25.  
  26. // Prompts the user to input the name of the Client machine they which to connect to.
  27. If Input ("Please enter the name of the Client you wish to connect to", Client) = False then
  28.     Print " "
  29.     Print " This script will now stop!"
  30.     Print "******************************"
  31.     Stop
  32. Else
  33.     // Performs an error check, if the connection to the Client is good it will open the window but if the connection is unsuccesful 
  34.     If Connect(Client) = True then 
  35.         Print " "   
  36.         Print "A view window of the ", Client, " will now be"
  37.         Print "opened" 
  38.         Wait (4)
  39.         SetWindowMode (2)
  40.         Watch()
  41.         WaitEndView()
  42.     Else
  43.         Print " "
  44.         Print "You were unable to connect to ", Client
  45.         Print "***********************************************"
  46.     Endif
  47.  
  48.     // Disconnects from the Client machine
  49.     Disconnect(Client)
  50.     Print " "
  51.     Print "The script has now disconnected from ", Client
  52.   
  53.     Print "*********************************************************"
  54.     Print " "
  55.     Print "To edit or view the contents of this"
  56.     Print "script right mouse button click"
  57.     Print "on the Script icon and select Edit" 
  58.  
  59. Endif
  60.  
  61.  
  62. //Copyright ⌐ 2000